﻿using System;
using System.Collections.Generic;
using System.Collections;
using System.Linq;
using System.Text;

namespace PowerWaveAddin
{
    class SlideSyncQueue : Queue<Int32>
    {
        private Object lockToken;

        public SlideSyncQueue()
        {
            lockToken = new Object();
        }

        public void Enqueue(Int32 obj)
        {
            lock (lockToken)
            {
                base.Clear();
                base.Enqueue(obj);
            }
        }

        private Int32 Dequeue()
        {
            lock (lockToken)
            {
                Int32 val = base.Dequeue();
                return val;
            }
        }
    }

    class SlideSyncEventArgs : EventArgs
    {
        private SlideSyncQueue ssq;

        internal SlideSyncQueue SlideSyncQueue
        {
            get { return ssq; }
            set { ssq = value; }
        }

        public SlideSyncEventArgs(SlideSyncQueue ssq)
        {
            this.ssq = ssq;
        }
    }
}
